-- GENERATED SPELL FOR [Coldmist Widow] --


function spell0_16171(pUnit, Event) --@Frost Mist,Self--
pUnit:FullCastSpellOnTarget(29292,pUnit)
pUnit:RegisterEvent('Sorts_16171', 10342, 1)
end

function spell1_16171(pUnit, Event) --@Poison Bolt Volley,n/a--
pUnit:FullCastSpellOnTarget(29293,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_16171', 17500, 1)
end

function Sorts_16171(pUnit, Event)
local choix_sorts_16171 = math.random(0, 1)
if choix_sorts_16171 == 0 then
pUnit:RegisterEvent('spell0_16171', 1, 1)
end
if choix_sorts_16171 == 1 then
pUnit:RegisterEvent('spell1_16171', 1, 1)
end
end

function mob16171_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_16171', math.random(1500, 3000), 1)
end

function mob16171_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob16171_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob16171_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(16171, 1, 'mob16171_Action')
RegisterUnitEvent(16171, 2, 'mob16171_Leave')
RegisterUnitEvent(16171, 3, 'mob16171_Kill')
RegisterUnitEvent(16171, 4, 'mob16171_Die')
